<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <style>
        body {
            margin: 0;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
        }

        /* 布局样式 */
        .main-container {
            display: flex;
            width: 520px;
            height: 340px;
            overflow: hidden;
        }

        .sidebar {
            width: 60px;
            background-color: #f5f5f5;
            border-right: 1px solid #ddd;
            padding: 12px 6px;
        }

        .content {
            flex: 1;
            padding: 16px 20px;
            overflow: hidden;
            position: relative;
        }

        /* 菜单项样式 */
        .menu-item {
            padding: 8px 4px;
            margin: 4px 0;
            cursor: pointer;
            border-radius: 4px;
            transition: background-color 0.2s;
            text-align: center;
            font-size: 12px;
        }

        .menu-item:hover {
            background-color: #e8e8e8;
        }

        .menu-item.active {
            background-color: #336dab;
            color: white;
        }

        .content-page {
            display: none;
        }

        .content-page.active {
            display: block;
        }
    </style>
    <link rel="stylesheet" href="components/switch.css">
    <link rel="stylesheet" href="components/tools.css">
</head>
<body>
    <div class="main-container">
        <div class="sidebar">
            <div class="menu-item active" data-page="switch">切换</div>
            <div class="menu-item" data-page="tools">工具</div>
            <!-- 这里可以添加更多菜单项 -->
        </div>
        
        <div class="content">
            <!-- 这里使用动态加载的方式加载switch.html -->
        </div>
    </div>
    <script type="module" src="../common/toast.js"></script>
    <script type="module" src="popup.js"></script>
</body>
</html>